﻿@{
    Layout = null;
}
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title></title>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
    <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
    <meta http-equiv="Pragma" content="no-cache" />
    <meta http-equiv="Expires" content="0" />
    <meta http-equiv="Cache" content="no-cache" />
    <link rel="stylesheet" href="~/Scripts/ligerUI/skins/Aqua/css/ligerui-all.css" />
    <link rel="stylesheet" href="~/Scripts/ligerUI/skins/ligerui-icons.css" />
    <link rel="stylesheet" href="~/Scripts/ligerUI/skins/Gray/css/all.css" />
    <script src="~/Scripts/jquery-1.10.2.min.js"></script>
    <script src="~/Scripts/ligerUI/js/ligerui.all.js"></script>
    <script src="~/Scripts/common.js"></script>
    <style>
        .topPosition {
            width: 100%;
            height: 50px;
            text-align: center;
            background-color: #f1f6f8;
        }

        .patientsDiv {
            float: left;
            width: 200px;
            height: 25px;
            line-height: 25px;
            background-color: #fff;
            border-radius: 5px;
            margin-left: 5px;
            text-align: center;
            margin-left: 20px;
            font-size: 13px;
            margin-top: 10px;
        }


        .lujing {
            margin-top: 10px;
            float: left;
            width: 120px;
            height: 25px;
            line-height: 25px;
            background-color: #fff;
            cursor: pointer;
            border-radius: 5px;
            margin-left: 10px;
            text-align: center;
            font-size: 13px;
        }

        .lujingcur {
            background-color: #02b9e3;
        }
    </style>
    <script>
        $(function () {
            $(".lujing").on("click", function () {
                $(".lujing").removeClass("lujingcur");
                $(this).addClass("lujingcur");
                var types = ($(this).attr("data-type"));
                initTable(types)
            })
        })
    </script>
</head>
<body>
    <div class="topPosition">
        <div class="patientsDiv">
            张三&nbsp;&nbsp;男&nbsp;&nbsp;30岁
        </div>
        <div class="lujing lujingcur" data-type="1">胸痛</div>
        <div class="lujing" data-type="2">卒中</div>
        <div class="lujing" data-type="3">创伤</div>
    </div>
    <div class="topPosition">
        <div style="float:left;margin-left:10px;text-align :left;">
            入径：吴医生 2019-07-10 14:21
            <br />
            出径：
        </div>
        <div style="float:right;margin-right:10px;">
            <input type="button" value="路径对比" class="l-button" onclick="comprea(0)" />
            <input type="button" value="退出路径" class="l-button" />
        </div>
    </div>
    <div id="maingrid"></div>

    <script  >

        function comprea(uid) {
            var url = "/ChestPainCenter/MedicalRecords/Index";
            $.ligerDialog.open({
                height: 100,
                width: 100,
                title: '路径对比',
                data: { Id: uid },
                url: url,
                showMax: true,
                showToggle: false,
                showMin: false,
                isResize: false,
                slide: false,
                buttons: [{
                    text: '回调函数', onclick: function (i, d) {
                        $("#btnSearch").click();
                    }
                }]
            }).max();
        }

        var manager;

        $(function () {
            initTable(1);
        })
        ///加载列表
        function initTable(types) {
            var data;
            //创伤
            if (types == "1") {
                data = {
                    Rows: [
                        { StepName: "到达本院大门时间", Department: "", ExecuteName: "管理员", ExecuteTime: "2018-8-26 16:18", ExecutionRecord: "", TimeRemind: "耗时0分", LackRemind: "", Status: 1, TreatmentRecord: "" },
                        { StepName: "院内接诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "绕行或直达科室时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内首次心电图时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "首份心电图确诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "心电图远程传输时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "心内科医生会诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "启用导管室时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "溶栓时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "肌钙蛋白抽血时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "肌钙蛋白报告时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "出院时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "离开本院大门时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "转送其他医院到达时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "转送其他科室时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "其他科室接诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                    ]
                }
            }
            if (types == "2") {
                //卒中
                data = {
                    Rows: [
                        { StepName: "救护车到达现场时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "救护车到达医院时间", Department: "", ExecuteName: "管理员", ExecuteTime: "2018-8-26 16:18", ExecutionRecord: "", TimeRemind: "耗时0分", LackRemind: "", Status: 1, TreatmentRecord: "" },
                        { StepName: "院前院内交接时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "转出医院入门时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "决定转院时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "离开转出医院时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内接诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "神经内科首诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "完成头颅CT时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "发病时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "采血时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "初步诊断时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "疾病确诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "血液结果报告时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "疾病确诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "头颈部血管CTA开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "到达导管室时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "完成动脉置鞘时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "开始动脉取栓时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "血管再通时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "出院时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "签署静脉溶栓知情同意书时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "签署急诊取栓手术同意书时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "死亡时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "测末梢血糖时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "平扫CT报告时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "CT护士到达时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "完成头颈部血管CTA时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "收入卒中病房时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" }
                    ]
                }
            }
            if (types == "3") {
                //胸痛
                data = {
                    Rows: [
                        { StepName: "呼叫120时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "120到达时间", Department: "", ExecuteName: "管理员", ExecuteTime: "2018-8-26 16:18", ExecutionRecord: "", TimeRemind: "耗时0分", LackRemind: "", Status: 1, TreatmentRecord: "" },
                        { StepName: "首次医疗接触时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院前首次心电图时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院前心电图诊断时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "心肌酶谱采血时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "初步诊断时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "呼叫转科会诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "会诊医生到达时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内溶栓开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内心电图时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内心电图确诊时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "通知放射科时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "到达放射科时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "摄片开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "摄片诊断时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "导管室激活时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "呼叫120时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "120到达时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内医疗接触时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内首次心电图时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "心电图诊断时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "心肌酶谱采血时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "会诊医生到达时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院内溶栓开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "导管室激活时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "到达导管室时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "手术开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "手术结束时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "穿刺开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "穿刺成功时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "造影开始时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "造影结束时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "首次球囊扩张时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "转归时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "院前心电图诊断时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" },
                        { StepName: "救护车到达现场时间", Department: "", ExecuteName: "未执行", ExecuteTime: "", ExecutionRecord: "", TimeRemind: "", LackRemind: "", Status: 0, TreatmentRecord: "" }
                    ]
                }
            }
            manager = $("#maingrid").ligerGrid({
                height: '100%',
                heightDiff: 25,
                data: data,
                usePager: false,
                frozen: false,
                fixedCellHeight: false,
                columns: [
                    {
                        display: '项目', name: 'StepName', align: 'left', width: 150,
                        render: function (row) {
                            var html = "";
                            if (row.Status == 0) {
                                html += "<img src='../../Content/images/icon/1.png'/>&nbsp;"
                            }
                            else {
                                html += "<img src='../../Content/images/icon/10.png'/>&nbsp;"
                            }
                            html += "<a href='javascript:void(0);' onclick='showDetail()'>" + row.StepName + "</a>";
                            if (row.Department != "") {
                                html += "&nbsp;&nbsp;<fon style='color:#808080';>" + row.Department + "</font>"
                            }
                            return html;
                        }
                    },
                    { display: '执行人', name: 'ExecuteName', width: 100, editor: { type: 'text' }, isSort: false },
                    {
                        display: '执行时间', name: 'ExecuteTime', width: 150, editor: { type: 'date', showTime: true }, isSort: false, type: "date", format: "yyyy-MM-dd hh:mm:ss"
                    },
                    {
                        display: '诊疗记录', name: 'TreatmentRecord', align: 'left', render: function (row) {

                            var html = "<div style=\"width:100%;word-wrap:break-word\">" + row.TreatmentRecord + "</div>";
                            return html;

                        }
                    },
                    {
                        display: '时限提醒', name: 'TimeRemind', width: 100, render: function (row) {
                        }
                    },
                    {
                        display: '漏项提醒', name: 'LackRemind', width: 100, render: function (row) {
                        }
                    },
                    {
                        display: '操作', name: '', width: 180, render: function (rowdata, rowindex) {
                            return "<a href='javascript:showDetail(" + rowindex + ")'>编辑执行信息</a> ";
                        }
                    }
                ],
                enabledEdit: true,
                clickToEdit: false
            });

            GridNoData($("#maingrid"));
        }

        function showDetail(id) {
            $.ligerDialog.open({
                height: 500,
                width: 650,
                title: '添加诊疗内容',
                data: { Id: id },
                url: '../PathwayExe/Detail',
                showMax: true,
                showToggle: false,
                showMin: false,
                isResize: false,
                slide: false,
                buttons: [{
                    text: '回调函数', onclick: function (i, d) {
                        $("#btnSearch").click();
                    }
                }]
            }).max();
            $(".l-dialog-buttons").hide();
        }

        function beginEdit(rowid) {
            for (var i = 0; i < manager.getData().length; i++) {
                if (i == rowid) {
                    manager.beginEdit(i);
                }
                else {
                    manager.cancelEdit(i);
                }
            }
        }
        function cancelEdit(rowid) {
            manager.cancelEdit(rowid);
        }
        function endEdit(rowid) {
            manager.endEdit(rowid);
        }
    </script>
</body>
</html>